package com.cnswhy.cloud.server.core.dto;

import java.time.LocalDateTime;
import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.cnswhy.cloud.common.core.base.entity.Entity;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.Range;
import lombok.Data;
import lombok.Builder;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.AllArgsConstructor;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.io.Serializable;

/**
 * <p>
 * 实体类
 * 商品订单详情表
 * </p>
 *
 * @author cnswhy
 * @since 2020-11-07
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = false)
@Builder
@ApiModel(value = "ShopOrderDetailPageDTO", description = "商品订单详情表")
public class ShopOrderDetailPageDTO implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 所属订单id
     */
    @ApiModelProperty(value = "所属订单id")
    @NotNull(message = "所属订单id不能为空")
    private Long orderId;
    /**
     * 商品id
     */
    @ApiModelProperty(value = "商品id")
    @NotNull(message = "商品id不能为空")
    private Long productId;
    /**
     * 库存id
     */
    @ApiModelProperty(value = "库存id")
    private Long stockId;
    /**
     * 商品名称
     */
    @ApiModelProperty(value = "商品名称")
    @NotEmpty(message = "商品名称不能为空")
    @Length(max = 200, message = "商品名称长度不能超过200")
    private String productName;
    /**
     * 商品图片
     */
    @ApiModelProperty(value = "商品图片")
    @NotEmpty(message = "商品图片不能为空")
    @Length(max = 500, message = "商品图片长度不能超过500")
    private String productImg;
    /**
     * 规格值组合，例如：红色,大码
     */
    @ApiModelProperty(value = "规格值组合，例如：红色,大码")
    @Length(max = 1000, message = "规格值组合，例如：红色,大码长度不能超过1000")
    private String specValues;
    /**
     * 商品单价
     */
    @ApiModelProperty(value = "商品单价")
    @NotNull(message = "商品单价不能为空")
    private BigDecimal costPrice;
    /**
     * 商品编码
     */
    @ApiModelProperty(value = "商品编码")
    @NotEmpty(message = "商品编码不能为空")
    @Length(max = 50, message = "商品编码长度不能超过50")
    private String productNo;
    /**
     * 实付金额
     */
    @ApiModelProperty(value = "实付金额")
    @NotNull(message = "实付金额不能为空")
    private BigDecimal amount;
    /**
     * 数量
     */
    @ApiModelProperty(value = "数量")
    @NotNull(message = "数量不能为空")
    private Integer num;
    /**
     * 抵扣积分
     */
    @ApiModelProperty(value = "抵扣积分")
    private BigDecimal deductionIntegral;
    /**
     * 状态：1-待发货 2-已发货 3-待退款 4-拒绝退款 5-已退款
     */
    @ApiModelProperty(value = "状态：1-待发货 2-已发货 3-待退款 4-拒绝退款 5-已退款")
    @NotNull(message = "状态：1-待发货 2-已发货 3-待退款 4-拒绝退款 5-已退款不能为空")
    private Integer status;
    /**
     * 结算价
     */
    @ApiModelProperty(value = "结算价")
    private BigDecimal settlementPrice;
    @ApiModelProperty(value = "")
    @Length(max = 255, message = "长度不能超过255")
    private String url;

}
